package com.crm.service.impl.userForumManager;

import com.crm.dao.mapper.customMapper.userForumCustomManager.UserForumLikeCustomMapper;
import com.crm.dao.mapper.userForumManager.UserForumLikeMapper;
import com.crm.model.entity.userForumManager.UserForumLike;
import com.crm.service.userForumManager.UserForumLikeDbService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Author:chaifuyou
 * @Date: 2021/5/24 9:44
 */
@Service
public class UserForumLikeDbServiceImpl implements UserForumLikeDbService {

    @Autowired
    private UserForumLikeMapper userForumLikeMapper;

    @Autowired
    private UserForumLikeCustomMapper userForumLikeCustomMapper;

    /**
     * 添加 点赞 收藏 转发
     * @param userForumLike
     */
    @Override
    public void addUserForumLike(UserForumLike userForumLike) {
        userForumLikeMapper.insertSelective(userForumLike);
    }

    /**
     * 取消 点赞 收藏 转发
     * @param userForumLike
     */
    @Override
    public void delUserForumLike(UserForumLike userForumLike) {
        userForumLikeCustomMapper.delUserForumLike(userForumLike);
    }
}
